siglent-sds: original driver fixes, USBTMC support#114
siglent-sds: original driver fixes, USBTMC support#114voneiden wants to merge 3 commits intosigrokproject:masterfrom
Conversation
6aae055 to
08bfb7f
Compare
f2cd6ad to
59972f4
Compare
|
OK, I will probably refactor this PR into multiple smaller PR's for the sake of easier review. |
59972f4 to
18a4d4d
Compare
043b6a7 to
d76584e
Compare
| /* Do not change the order of entries. */ | ||
| static const char *data_sources[] = { | ||
| "Display", | ||
| "Screen", |
There was a problem hiding this comment.
config_get for DATA_SOURCE returns "Screen" to the cli/pulseview, and since the enum is also DATA_SOURCE_SCREEN I decided to change these two occurrences of "Display" into "Screen".
d76584e to
f401971
Compare
|
Triggered by my bug report #1683 (https://sigrok.org/bugzilla/show_bug.cgi?id=1683) gsi prepared a fix for various memory leaks of the same kind, including the one in this PR. Matti, do you agree to the linked commitdiff, which will cause a conflict with your PR or do you prefer to keep it in your PR? |
|
@jr-oss Seems good. I'll drop them from the PR. |
|
But hey @jr-oss - that particular commit by gsi seems to be missing the initialization of a few pointers on the api.c side, see f401971#diff-da08cdaf0b1d2848262a936247e81c8de384dfed1eda9be625e9bd8a61eb8916R298 the g_free calls for these two will end up trying to free random points in the memory unless I'm mistaken, danger danger? |
f9b30f5 to
11d12fc
Compare
|
Just built and tested this with a Siglent SPD3303C connected to a Linux host through USB, but it gives the same errors as latest release or master: Is this PR supposed to solve that? 🤔 |
|
@LeSpocky Correct me if I'm wrong, but I believe SPD3303C uses the scpi-pps driver instead of siglent-sds driver. Try verbose logging ( Looks like same root cause anyway. |
|
I think you're right, I vaguely remember #77 addressing this and that's still open, too. Sorry for the noise. FWIW, verbose log output (parts): |
NOTE: Needs testing by someone who owns an older siglent scope.
Fixes a few memory leaks, one inconsistency with DATA_SOURCE and adds USBTMC support.
Addresses bugs
I've split off the eseries changes into a separate pull request #118 as that code should not require testing by someone with an older scope model.